
{{template "header" .}}
<body class="hold-transition sidebar-mini">
<div class="wrapper">
    <!-- Navbar -->
    <nav class="main-header navbar navbar-expand navbar-white navbar-light">
        <!-- Left navbar links -->
        <ul class="navbar-nav">

            <li class="nav-item">
                <a class="nav-link" data-widget="pushmenu" href="#" role="button"><i class="fas fa-bars"></i></a>
            </li>

            <li class="nav-item d-none d-sm-inline-block">
                <a href="/dashboard" class="nav-link">Home</a>
            </li>
            <li class="nav-item d-none d-sm-inline-block">
                <a href="#" class="nav-link">Class</a>
            </li>
        </ul>

        <!-- Right navbar links -->
        {{template "right_nav" .}}



    </nav>
    <!-- /.navbar -->

    <!-- Main Sidebar Container -->
    {{template "left_menu" .}}

    <!-- Content Wrapper. Contains page content -->
    <div class="content-wrapper">
        <!-- Content Header (Page header) -->
        <div class="content-header">
            <div class="container-fluid">
                <div class="row mb-2">
                    <div class="col-sm-6">
                        <h1 class="m-0">&nbsp;</h1>
                    </div><!-- /.col -->

                </div><!-- /.row -->
            </div><!-- /.container-fluid -->
        </div>
        <!-- /.content-header -->

        <!-- Main content -->
        <section class="content">
            <div class="container-fluid">
                <div class="row">
                    <div class="col-12">
                        <div class="card">

                            <!-- /.card-header -->
                            <div class="card-body">
                                <table id="example2" class="table table-bordered table-hover">
                                    <thead>
                                    <tr>
                                        <th>Class ID</th>
                                        <th>Class Nmae</th>
                                        <th>Date Range</th>
                                        <th>Teacher</th>
                                        <th>Students</th>
                                    </tr>
                                    </thead>
                                    <tbody>

                                    {{range $i, $v := .list}}



                                    <tr>
                                        <td>{{$v.Id}}</td>
                                        <td>{{$v.ClassName}}</td>
                                        <td>{{$v.DateRange}}</td>
                                        <td>{{$v.Teacher}}</td>
                                        <td>{{$v.StudentNumber}}</td>
                                    </tr>

                                    {{end}}



                                    </tbody>
                                    <tfoot>
                                    <tr>
                                        <th>Class ID</th>
                                        <th>Class Nmae</th>
                                        <th>Date Range</th>
                                        <th>Teacher</th>
                                        <th>Students</th>
                                    </tr>
                                    </tfoot>
                                </table>
                            </div>
                            <!-- /.card-body -->
                        </div>
                        <!-- /.card -->







                        <!-- /.card -->
                    </div>
                    <!-- /.col -->
                </div>
                <!-- /.row -->
            </div>
            <!-- /.container-fluid -->
        </section>
        <!-- /.content -->
    </div>
    <!-- /.content-wrapper -->




    {{template "copyright" .}}



</div>
<!-- ./wrapper -->


</body>


{{template "footer" .}}





<script type="text/javascript">
    $('.mt-2').find('.active').removeClass('active');

    $('.mt-2 #class-nav').addClass('active');
    $('#class-nav').parent().addClass("menu-is-opening menu-open");

    //$("a href='/class/list'").addClass('active');
    $('a[href="/class/list"]').addClass('active');

</script>